package com.zry.yard.utils

import com.zry.yard.R
import com.zry.yard.been.BasicBean
import com.zry.yard.been.HomePageBean
import com.zry.yard.been.PutState

class OneYardUtils {
    fun getHomePageList(basicList: MutableList<BasicBean>): MutableList<BasicBean> {
        basicList.forEach {
            when {
                it.BasicCode=="app01" -> it.BasicImg=R.mipmap.home_page_img01
                it.BasicCode=="app02" -> it.BasicImg=R.mipmap.home_page_img02
                it.BasicCode=="app03" -> it.BasicImg=R.mipmap.home_page_img03
                it.BasicCode=="app04" -> it.BasicImg=R.mipmap.home_page_img04
                it.BasicCode=="app05" -> it.BasicImg=R.mipmap.home_page_img05
                it.BasicCode=="app06" -> it.BasicImg=R.mipmap.home_page_img06
                it.BasicCode=="app07" -> it.BasicImg=R.mipmap.home_page_img07
                it.BasicCode=="app08" -> it.BasicImg=R.mipmap.home_page_img08
                it.BasicCode=="app09" -> it.BasicImg=R.mipmap.home_page_img09
            }
        }
        return basicList
    }


    fun getPutStorageState(): MutableList<PutState> {
        val putStateList: MutableList<PutState> = mutableListOf()
        putStateList.add(PutState(0, "未结单"))
        putStateList.add(PutState(1, "已结单"))
        return putStateList
    }

    fun getOutState(): MutableList<PutState> {
        val putStateList: MutableList<PutState> = mutableListOf()
        putStateList.add(PutState(1, "未结单"))
        putStateList.add(PutState(3, "已结单"))
        putStateList.add(PutState(4, "已收货"))
        return putStateList
    }
}